<?php
/**
 * +--------------------------------------------------------+
 * @Created by PhpStorm.
 * @Category HomeController.php
 * @Depiction:
 * Author: hwy
 * Date: 2020/5/15  17:31
 * +--------------------------------------------------------+
 */

namespace App\Http\Controllers\Index;


use App\Handlers\CollectHandle;
use App\Http\Controllers\Controller;
use App\Models\Article;
use App\Models\CollectArticle;
use App\Models\Stock;
use App\Models\WxArticle;
use App\Services\ArticleService;
use App\Services\CollectService;
use App\Services\SendMailService;
use Carbon\Carbon;
use Illuminate\Http\Request;
use Laravel\Socialite\Facades\Socialite;

class HomeController extends Controller
{

    public function index(Request $request)
    {
        //文章列表
        $req['perPage'] = 3;
        $article        = ArticleService::getInstance()->getList($req);
        $hot_article    = $article['data']['data'];
        //排行榜

        return view('index.home.index', compact('hot_article'));
    }


}
